module tests.qc.MonoidTest where

import Data.NonEmpty (nonEmpty)
import Data.Monoid (Monoid, sconcat, mconcat, <>)
import Test.QuickCheck

checkSemigroupConcat :: (Monoid a, Eq a) => a -> [a] -> Bool
checkSemigroupConcat head tail =
  head <> mconcat tail == sconcat (nonEmpty head tail)

p_semigroupConcatStrings =
  property (checkSemigroupConcat :: String -> [String] -> Bool)
